home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 5 / Skunkware 5.iso / include / Xm / BulletinBP.h < prev    next >
Encoding:
C/C++ Source or Header  |  1994-06-30  |  6.8 KB  |  221 lines

  1. /* 
  2.  * (c) Copyright 1989, 1990, 1991, 1992, 1993 OPEN SOFTWARE FOUNDATION, INC. 
  3.  * ALL RIGHTS RESERVED 
  4. */ 
  5. /* 
  6.  * Motif Release 1.2.3
  7. */ 
  8. /*   $RCSfile: BulletinBP.h,v $ $Revision: 10.1 $ $Date: 1994/02/03 15:34:35 $ */
  9. /*
  10. *  (c) Copyright 1989, DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS. */
  11. /*
  12. *  (c) Copyright 1987, 1988, 1989, 1990, 1991, 1992 HEWLETT-PACKARD COMPANY */
  13. #ifndef _XmBulletinBoardP_h
  14. #define _XmBulletinBoardP_h
  15.  
  16. #include <Xm/BulletinB.h>
  17. #include <Xm/ManagerP.h>
  18.  
  19. #ifdef __cplusplus
  20. extern "C" {
  21. #endif
  22.  
  23.  
  24. /****************************************************************************
  25.  * this suffix is added to dialog shells created by Xm convenience routines *
  26.  * so that, for example, a call to create a form dialog named f generates a *
  27.  * dialog shell named f_popup in addition to a form named f                 *
  28.  ****************************************************************************/
  29.  
  30. #define XmDIALOG_SUFFIX        "_popup"
  31. #define XmDIALOG_SUFFIX_SIZE    6
  32.  
  33. /* Constraint part record for bulletin board */
  34.  
  35. typedef struct _XmBulletinBoardConstraintPart
  36. {
  37.    char unused;
  38. } XmBulletinBoardConstraintPart, * XmBulletinBoardConstraint;
  39.  
  40.  
  41. /*  New fields for the BulletinBoard widget class record  */
  42.  
  43. typedef struct
  44. {
  45.     Boolean            always_install_accelerators;
  46.     XmGeoCreateProc         geo_matrix_create ;
  47.     XmFocusMovedProc    focus_moved_proc ;
  48.     XtPointer            extension;
  49. } XmBulletinBoardClassPart;
  50.  
  51.  
  52. /* Full class record declaration */
  53.  
  54. typedef struct _XmBulletinBoardClassRec
  55. {
  56.     CoreClassPart        core_class;
  57.     CompositeClassPart    composite_class;
  58.     ConstraintClassPart    constraint_class;
  59.     XmManagerClassPart    manager_class;
  60.     XmBulletinBoardClassPart    bulletin_board_class;
  61. } XmBulletinBoardClassRec;
  62.  
  63. externalref XmBulletinBoardClassRec xmBulletinBoardClassRec;
  64.  
  65.  
  66. /* New fields for the BulletinBoard widget record */
  67.  
  68. typedef struct
  69. {
  70.     Dimension    margin_width;        /*  margins        */
  71.     Dimension    margin_height;
  72.  
  73.     Widget        default_button;        /*  widgets        */
  74.     Widget        dynamic_default_button;    /*  widgets        */
  75.     Widget        cancel_button;
  76.     Widget        dynamic_cancel_button;
  77.  
  78.     XtCallbackList    focus_callback;        /*  callback lists    */
  79. #ifdef BB_HAS_LOSING_FOCUS_CB
  80.     XtCallbackList    losing_focus_callback;    /*  callback lists    */
  81. #endif
  82.     XtCallbackList    map_callback;
  83.     XtCallbackList    unmap_callback;
  84.  
  85.     XtTranslations    text_translations;
  86.  
  87.     XmFontList    button_font_list;    /*  font lists        */
  88.     XmFontList    label_font_list;
  89.     XmFontList    text_font_list;
  90.  
  91.     Boolean        allow_overlap;        /*  policies        */
  92.     Boolean        default_position;
  93.     Boolean        auto_unmanage;
  94.     unsigned char    resize_policy;
  95.  
  96.     Dimension        old_width;        /*  shadow resources    */
  97.     Dimension        old_height;
  98.     Dimension        old_shadow_thickness;
  99.     unsigned char    shadow_type;
  100.  
  101.     Boolean        in_set_values;        /*  internal flag    */
  102.     Boolean        initial_focus ;
  103.  
  104.     Boolean        no_resize;        /*  dialog resources    */
  105.     unsigned char    dialog_style;
  106.     XmString    dialog_title;
  107.     Widget        shell;
  108.     Widget        _UNUSED;
  109.  
  110.     XmGeoMatrix     geo_cache ;        /* Cache for geometry management.*/
  111. } XmBulletinBoardPart;
  112.  
  113.  
  114. /****************************************************************
  115.  *
  116.  * Full instance record declaration
  117.  *
  118.  ****************************************************************/
  119.  
  120. typedef struct _XmBulletinBoardRec
  121. {
  122.     CorePart        core;
  123.     CompositePart        composite;
  124.     ConstraintPart        constraint;
  125.     XmManagerPart        manager;
  126.     XmBulletinBoardPart    bulletin_board;
  127. } XmBulletinBoardRec;
  128.  
  129.  
  130. #define BB_CancelButton(w) \
  131.                   (((XmBulletinBoardWidget) w)->bulletin_board.cancel_button)
  132. #define BB_DynamicCancelButton(w) \
  133.           (((XmBulletinBoardWidget) w)->bulletin_board.dynamic_cancel_button)
  134. #define BB_DefaultButton(w) \
  135.                  (((XmBulletinBoardWidget) w)->bulletin_board.default_button)
  136. #define BB_DynamicDefaultButton(w) \
  137.          (((XmBulletinBoardWidget) w)->bulletin_board.dynamic_default_button)
  138. #define BB_MarginHeight(w) \
  139.                   (((XmBulletinBoardWidget) w)->bulletin_board.margin_height)
  140. #define BB_MarginWidth(w) \
  141.                    (((XmBulletinBoardWidget) w)->bulletin_board.margin_width)
  142. #define BB_ButtonFontList(w) \
  143.                (((XmBulletinBoardWidget) w)->bulletin_board.button_font_list)
  144. #define BB_LabelFontList(w) \
  145.                 (((XmBulletinBoardWidget) w)->bulletin_board.label_font_list)
  146. #define BB_TextFontList(w) \
  147.                  (((XmBulletinBoardWidget) w)->bulletin_board.text_font_list)
  148. #define BB_StringDirection(w) \
  149.                       (((XmBulletinBoardWidget) w)->manager.string_direction)
  150. #define BB_ResizePolicy(w) \
  151.               (((XmBulletinBoardWidget) w)->bulletin_board.resize_policy)
  152. #define BB_InSetValues(w) \
  153.           (((XmBulletinBoardWidget) w)->bulletin_board.in_set_values)
  154. #define BB_InitialFocus(w) \
  155.           (((XmBulletinBoardWidget) w)->bulletin_board.initial_focus)
  156.  
  157.  
  158. /********    Private Function Declarations    ********/
  159. #ifdef _NO_PROTO
  160.  
  161. extern Widget _XmBB_CreateButtonG() ;
  162. extern Widget _XmBB_CreateLabelG() ;
  163. extern void _XmBulletinBoardSizeUpdate() ;
  164. extern void _XmBulletinBoardFocusMoved() ;
  165. extern void _XmBulletinBoardReturn() ;
  166. extern void _XmBulletinBoardCancel() ;
  167. extern void _XmBulletinBoardMap() ;
  168. extern void _XmBulletinBoardSetDefaultShadow() ;
  169. extern void _XmBulletinBoardSetDynDefaultButton() ;
  170. extern void _XmBBUpdateDynDefaultButton() ;
  171.  
  172. #else
  173.  
  174. extern Widget _XmBB_CreateButtonG( 
  175.                         Widget bb,
  176.                         XmString l_string,
  177.                         char *name) ;
  178. extern Widget _XmBB_CreateLabelG( 
  179.                         Widget bb,
  180.                         XmString l_string,
  181.                         char *name) ;
  182. extern void _XmBulletinBoardSizeUpdate( 
  183.                         Widget wid) ;
  184. extern void _XmBulletinBoardFocusMoved( 
  185.                         Widget wid,
  186.                         XtPointer client_data,
  187.                         XtPointer data) ;
  188. extern void _XmBulletinBoardReturn( 
  189.                         Widget wid,
  190.                         XEvent *event,
  191.                         String *params,
  192.                         Cardinal *numParams) ;
  193. extern void _XmBulletinBoardCancel( 
  194.                         Widget wid,
  195.                         XEvent *event,
  196.                         String *params,
  197.                         Cardinal *numParams) ;
  198. extern void _XmBulletinBoardMap( 
  199.                          Widget wid,
  200.                          XEvent *event,
  201.                          String *params,
  202.                          Cardinal *numParams) ;
  203. extern void _XmBulletinBoardSetDefaultShadow( 
  204.                         Widget button) ;
  205. extern void _XmBulletinBoardSetDynDefaultButton( 
  206.                         Widget wid,
  207.                         Widget newDefaultButton) ;
  208. extern void _XmBBUpdateDynDefaultButton( 
  209.                          Widget bb) ;
  210.  
  211. #endif /* _NO_PROTO */
  212. /********    End Private Function Declarations    ********/
  213.  
  214.  
  215. #ifdef __cplusplus
  216. }  /* Close scope of 'extern "C"' declaration which encloses file. */
  217. #endif
  218.  
  219. #endif /* _XmBulletinBoardP_h */
  220. /* DON'T ADD ANYTHING AFTER THIS #endif */
  221.